<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="base.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<link rel="stylesheet" type="text/css" href="style/style.css"/>
<style type="text/css" >
			span{
				display:none;
			}
		</style>
		<script type="text/javascript" src="${basePath }/script/jquery-1.3.2.min.js"></script>
			<script type="text/javascript" charset="utf-8" src="${basePath }/script/kindeditor-min.js"></script>
	<script type="text/javascript">
		KE.show({
			id : 'content',
				allowPreviewEmoticons : true,
				allowUpload : true,
				imageUploadJson:'${basePath}/script/ke/upload_json.jsp',
				items : [
				'fontname', 'fontsize', '|', 'textcolor', 'bgcolor', 'bold', 'italic', 'underline',
				'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
				'insertunorderedlist', '|', 'emoticons', 'image', 'link']
		});
	</script>
		<script type="text/javascript">
			$(document).ready(function(){
				$("#saveForm").submit(function(){
					if($.trim($("#title").val()) == null){
						$(".titlemsg").css("display","block");
						return false;
					}
					if($.trim($("#content").val()) == null){
					 	$(".contentmsg").css("display","block");
					 	return false;
					}
					if($.trim($("#tag").val()) == null){
					 	$(".tagmsg").css("display","block");
					 	return false;
					}
					return true;
					});
				});
			</script>
</head>

<body>
<%@include file="template/top.jsp" %>

<div id="contain">
<div class="nav">
    	<a href="index.jspx">论坛首页</a>
        &gt;
        &gt;
       发表新帖子
  </div>	
  <div class="board">
  	<div class="board_title">
    	发表新帖子
    </div>
    <div class="newpostform">
        <div class="newpost">
                <div class="error" style="width:300px;display:none">
                    用户名或密码错误
                </div>
                <form action="tie.jspx" method="post" id="saveForm">
                	<input type="hidden" name="_method" value="save"/>
                	<input type="hidden" name="typeid" value="${typeid }"/> 
                    <label>标题：</label>
                    <input type="text" name="title" id="title" class="text"/>
                    <span class="titlemsg">标题不能为空</span>
                    <label>内容：</label>
                    <textarea id="content" name="content" class="textareastyle"></textarea>
                    <span class="contentmsg">内容不能为空</span>
                    <label>标签</label>
                    <input type="text" id="tag" name="tag"/>
                    <span class="tagmsg">标签不能为空</span>
                    <div>
                        <input type="submit" value="发表新帖"/>
                    </div>
                </form>
        </div>
    </div>
  </div>
</div>

<%@include file="template/footer.jsp" %>
</body>
</html>
